1. Field of the Invention
The present invention relates to a data processing apparatus, method, and program that process job data sent from a computer on a network, in accordance with a type of the job data.
2. Description of the Related Art
Network printers that are connected to a plurality of computers via networks such as LANs and that execute printing according to print requests from computers on the networks are commonly used. Generally, when print data from a plurality of computers is sent to the network printers, the print data is sent to a particular well-known port. For example, port number 515 is generally used for LPD, and port number 80 is generally used for HTTP.
Also, techniques for allowing a printer on a network to use a plurality of printing ports and to assign printing ports on a computer-by-computer basis are known. FIG. 11 shows exchange of data between host computers and a printer according to such techniques.
In more detail, first, in step S1101, the printer receives a print start request (create_job) from a computer on the network (hereinafter referred to as host computer A). The operation then proceeds to step S1102. In step S1102, if the create_job received from host computer A properly includes information such as an instruction regarding processing of a print job, the printer opens a printing port for receiving print data, and sends to host computer A a URI that serves as a destination when host computer A sends print data (hereinafter referred to as URI1). As described above, a port is specified using a URI. Then, in step S1103, a create_job is received from another computer on the network (hereinafter referred to as host computer B). Next, in step S1104, like in step S1102, a URI is sent, except the URI is sent to host computer B, and the URI is URI2 instead of URI1.
The URIs that serve as destinations for sending print data differ among host computers, and accordingly the ports that are used also differ among host computers.
In step S1105, in order to send print data, host computer A establishes a connection with the port represented by URI1 given in step S1102. The operation then proceeds to step S1106, in which print data is sent to the printer, and printing is executed.
Techniques of using a plurality of printing ports by assigning print ports individually for host computers that issue print start requests as described above are known.
Japanese Patent Laid-Open No. 2002-333958 (corresponding US Patent Application Publication No. 2002/0154333 A1) discloses an image processing apparatus that specifies host computers allowed to use ports individually for various ports, such as printing ports, management ports, and copying ports, and that allows or denies processing for job requests by host computers, such as printing requests, management requests, and copying requests. Also, techniques of dynamically assigning ports instead of using fixed port numbers on the basis of types of data processing are also disclosed.
According to the related art, the ports used for printing vary among host computers that issue print start requests. This requires management of port status as to whether or not each port is being used by one of the host computers. Furthermore, according to the related art, although ports used for printing vary among host computers, printing is executed even when print data is sent to URI1 by a host computer other than host computer A. Thus, printing could be blocked by a malicious user.